1. Field of the Invention
The present invention relates to a semiconductor disk drive that is connected to a host apparatus consisting of information processing devices and is used as a memory medium that uses a non-volatile memory that allows early-stage defects of flash memory and the like at a predetermined ratio. The present invention also relates to a method of creating a logical/physical address conversion table in the semiconductor disk drive.
2. Description of the Related Art
At present, flash memory is known to the public as a non-volatile memory that allows electric erasing and writing. The erasing operation in flash memory is usually performed by a batch erasing method for a plurality of memory cells. However, flash memory that allows erasing and writing in units of sectors has been developed as a product of recent years. Then a process of applying the new product to a semiconductor disk drive having the same interface as in the magnetic disk drive is currently in progress. A control circuit that allows the management of defects of the medium is installed in such a disk drive. A memory device called MGM (Mostly Good Memory) that allows early-stage defects at some ratio is developed as a product for the purpose of increasing the manufacturing yield of highly integrated flash memory.
In such a flash memory having early-stage defects, a nondefectiveness code is written before shipping, in units of sectors or blocks, which are the units of erasing, to indicate whether a sector or block is defective or nondefective. For example, in 64 Mb flash memory of the AND type that allows erasing and writing in units of sectors, each sector consists of 528 B composed of a data area of 512 B and a management area of 16 B.
FIG. 6 illustrates the states of sectors in prior 64 Mb flash memory of the AND type and the nondefectiveness code written in their management areas. Referring to FIG. 6, if one sector consists of 528 B, then a 64 Mb flash memory consists of 16384 sectors or 2048 blocks with one block consisting of 8 sectors. In this construction, a 6 B nondefectiveness code, for example xe2x80x9cABCxe2x80x9d in FIG. 6, is written only in the management area of each nondefective sector.
The reading and writing of data from and into the two areas, the data area and the management area, may be respectively performed independently of each other. However, the erasing of data can be performed only in units of sectors or blocks. The reading of data is performed in units of sectors, so that an initial access time of several microseconds is required for reaching the head of the data. However, after the initial access time, the data can be sequentially read out at a clock cycle of tens of nanoseconds for each sector.
However, in previously-known flash memory of such a construction, the nondefectiveness code must be confirmed each time a sector is accessed. Further, when data is erased, the nondefectiveness code is also erased, so that the operation of sheltering the nondefectiveness code before erasing and the operation of rewriting the nondefectiveness code after erasing are necessary. Such operations of confirming and preserving the nondefectiveness code cause the reduction in the performance of a disk drive that uses such a memory.
Therefore, there has been provided a logical/physical address conversion table that converts each logical sector address assigned by the host apparatus to a physical sector address of a nondefective sector. The host apparatus can access a usable nondefective sector at high speed by referring to the conversion table. In an example of creating such a logical/physical address conversion table, the physical address in flash memory corresponding to the logical address 0 is determined as follows.
First, the management area of the sector at physical address 0 is examined to test whether the sector at physical address 0 is usable or not. If it is usable, then the physical address 0 is determined to be the one corresponding to the logical address 0 and is written in the logical/physical address table. If the sector of physical address 0 is unusable, then whether the sector of physical address 1 is usable or not is tested. In this way, the physical addresses corresponding to all the logical addresses of the flash memory are obtained and successively stored in the table.
However, when a logical/physical address conversion table is created according to this method, the nondefectiveness code should be read out for all the logical addresses of flash memory. Therefore, it requires a substantial amount of time to create the logical/physical conversion table in a semiconductor disk drive of large capacity.
In Japanese Patent Laid-Open Publication No. 63-59618, there is disclosed a semiconductor RAM in which a sector management table is installed to record 0 and 1 depending on whether each sector is defective or not. In Japanese Patent Laid-Open Publication No. 9-212411, there is disclosed a flash memory card in which a volatile memory is installed to store address information about usable blocks. They store the address information and defective-sector information in volatile memory.
In order to solve the above problem, the object of the present invention is to obtain a semiconductor disk drive and a method of creating a physical/logical conversion table that use a non-volatile memory of MGM such as flash memory and the like, that access a nondefective sector or block at high speed, and that shorten the time for creating the logical/physical address conversion table.
A semiconductor disk drive in accordance with the present invention uses MGM, which allows early-stage defects at a predetermined ratio, and is used with a host apparatus consisting of information processing devices. The semiconductor disk drive comprises an interface section that interfaces with the host apparatus, a memory section that is composed of a volatile memory of MGM for which writing and erasing are electrically performed, and a control section that transfers data between the host apparatus and the disk drive through the interface section, converts logical sector addresses to physical sector addresses of the memory section, and performs memory management. The memory section has at least one sector in which address information about defective sectors is stored. The control section creates a logical/physical address conversion table based on the address information about defective sectors stored in the memory section.
According to the above construction, when a logical/physical address conversion table is created, the number of times the volatile memory in the memory section is accessed to obtain the addresses of defective sectors can be reduced. Therefore, the logical/physical address conversion table can be created at high speed.
Further, in the memory section, a management code may be written in a predetermined area of each sector in which address information about defective sectors is stored. The management code indicates that address information about defective sectors is stored in that sector. Then the control section reads out address information about defective sectors from the sectors in which the management code is written. In this case, when creating a logical/physical address conversion table, the control section finds out the sectors in which address information about defective sectors is stored, by checking the management code. In this way, the number of times the volatile memory in the memory section is accessed to obtain the addresses of defective sectors can be reduced. Therefore, the logical/physical address conversion table can be created at high speed.
Further, in the memory section, address information about defective sectors may be stored in the first or last block. In this case, the control section knows the block in which address information about defective sectors is stored. In this way, the number of times the volatile memory in the memory section is accessed to obtain the addresses of defective sectors can be further reduced. Therefore, the logical/physical address conversion table can be created at high speed.
As an alternative method, in the memory section, address information about defective sectors may be stored in the first usable block or the last usable block. In this case, the control section knows the block in which address information about defective sectors is stored. In this way, the number of times the volatile memory in the memory section is accessed to obtain the addresses of defective sectors can be reduced. Therefore, the logical/physical address conversion table can be created at high speed. Moreover, even if the first or last block in the memory section contains an unusable sector, the disk drive can be used, so that the yield of the memory devices can be increased.
Further, in the memory section, address information about defective sectors may be successively stored in sectors from the first address forward or from the last address backward. In this case, the control section knows the sectors in which address information about defective sectors is stored. In this way, the number of times the volatile memory in the memory section is accessed to obtain the addresses of defective sectors can be reduced. Therefore, the logical/physical address conversion table can be created at high speed.
Further, address information about defective sectors may be successively stored in usable sectors from the first usable sector forward or from the last usable sector backward. In this case, the control section knows the sectors in which address information about defective sectors is stored. In this way, the number of times the volatile memory in the memory section is accessed to obtain the addresses of defective sectors can be reduced. Therefore, the logical/physical address conversion table can be created at high speed. Moreover, even if the first or last sector in the memory section is an unusable sector, the disk drive can be used, so that the yield of the memory devices can be increased.
The method of creating the logical/physical address conversion table in accordance with the present invention is a method of creating a logical/physical address conversion table in a memory section of a semiconductor disk drive that uses a memory device MGM, which allows first-stage defects at a predetermined ratio. The present method writes address information indicating the addresses of defective sectors and a management code indicating a sector in which the address information is stored, in at least one predetermined sector of the memory section. Then the method reads out the address information about defective sectors from the sectors in which the management code is written and creates a logical/physical address conversion table, based on the address information about defective sectors.
According to this method, when the logical/physical address conversion table is created, the sectors in which address information about defective sectors are known. In this way, the number of times the volatile memory in the memory section is accessed to obtain the addresses of defective sectors can be reduced. Therefore, the logical/physical address conversion table can be created at high speed.
In implementing this method, the predetermined sectors may be sectors in a first block or the last block. In this case, when the logical/physical conversion table is created, the block in which address information about defective sectors is written is known. In this way, the number of times the volatile memory in the memory section is accessed to obtain the addresses of defective sectors can be reduced. Therefore, the logical/physical address conversion table can be created at high speed.